package gui.panel;

import j_util.Utiles;

import javax.swing.*;
import java.awt.*;
import java.awt.event.ActionEvent;
import java.awt.event.ActionListener;
/*

    This file is part of Logica-Logike.

    Logica-Logike is free software: you can redistribute it and/or modify
    it under the terms of the GNU Lesser General Public License as published by
    the Free Software Foundation version 3 of the License.

    Logica-Logike is distributed in the hope that it will be useful,
    but WITHOUT ANY WARRANTY; without even the implied warranty of
    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
    GNU Lesser General Public License for more details.

    You should have received a copy of the GNU Lesser General Public License
    along with Logica-Logike.  If not, see <http://www.gnu.org/licenses/>.

 */
/**
 * Extension de JPanel, referido a la funcionalidad y visualizacion de cuadro de oposicion.
 * Codigo poco mantenible, se considera su eliminacion en algun momento;
 * @author Jose Martin Rozanec;
 *
 * @deprecated;
 */
public class OposicionPanel extends JPanel {
    private javax.swing.JButton aFalsaButton;
    private javax.swing.JLabel aLabel;
    private javax.swing.JButton aVerdaderaButton;
    private javax.swing.JPanel bottomPanel;
    private javax.swing.JLabel contradiccionLabel;
    private javax.swing.JLabel contrariedadLabel;
    private javax.swing.JLabel cuadroLabel;
    private javax.swing.JPanel cuadroPanel;
    private javax.swing.JLabel def1Label;
    private javax.swing.JLabel def2Label;
    private javax.swing.JLabel def3Label;
    private javax.swing.JLabel def4Label;
    private javax.swing.JButton eFalsaButton;
    private javax.swing.JLabel eLabel;
    private javax.swing.JButton eVerdaderaButton;
    private javax.swing.JLabel fLabel;
    private javax.swing.JButton iFalsaButton;
    private javax.swing.JLabel iLabel;
    private javax.swing.JButton iVerdaderaButton;
    private javax.swing.JPanel mainPanel;
    private javax.swing.JButton oFalsaButton;
    private javax.swing.JLabel oLabel;
    private javax.swing.JButton oVerdaderaButton;
    private javax.swing.JPanel referenciaPanel;
    private javax.swing.JButton resetButton;
    private javax.swing.JLabel subalternaLabel;
    private javax.swing.JLabel subcontrariedadLabel;
    private javax.swing.JLabel vLabel;
    private javax.swing.JLabel v_fLabel;

    /**
     * Constructor;
     */
    public OposicionPanel() {
        initComponents();
    }

    /**
     * Inicializa los elementos del OposicionPanel y dispone los elementos visuales del mismo;
     */
    private void initComponents() {

        bottomPanel = new javax.swing.JPanel();
        contradiccionLabel = new javax.swing.JLabel();
        contrariedadLabel = new javax.swing.JLabel();
        subcontrariedadLabel = new javax.swing.JLabel();
        subalternaLabel = new javax.swing.JLabel();
        def1Label = new javax.swing.JLabel();
        def2Label = new javax.swing.JLabel();
        def3Label = new javax.swing.JLabel();
        def4Label = new javax.swing.JLabel();
        mainPanel = new javax.swing.JPanel();
        cuadroPanel = new javax.swing.JPanel();
        cuadroLabel = new javax.swing.JLabel();
        referenciaPanel = new javax.swing.JPanel();
        vLabel = new javax.swing.JLabel();
        fLabel = new javax.swing.JLabel();
        v_fLabel = new javax.swing.JLabel();
        resetButton = new javax.swing.JButton();
        aLabel = new javax.swing.JLabel();
        eLabel = new javax.swing.JLabel();
        iLabel = new javax.swing.JLabel();
        oLabel = new javax.swing.JLabel();
        aVerdaderaButton = new javax.swing.JButton();
        aFalsaButton = new javax.swing.JButton();
        eVerdaderaButton = new javax.swing.JButton();
        eFalsaButton = new javax.swing.JButton();
        iVerdaderaButton = new javax.swing.JButton();
        iFalsaButton = new javax.swing.JButton();
        oVerdaderaButton = new javax.swing.JButton();
        oFalsaButton = new javax.swing.JButton();

        bottomPanel.setBorder(javax.swing.BorderFactory.createCompoundBorder(javax.swing.BorderFactory.createTitledBorder(new javax.swing.border.LineBorder(new java.awt.Color(204, 204, 204), 1, true), "Teoria"), javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.LOWERED)));

        contradiccionLabel.setFont(new java.awt.Font("Tahoma", 1, 11)); // NOI18N
        contradiccionLabel.setText("Contradiccion:");

        contrariedadLabel.setFont(new java.awt.Font("Tahoma", 1, 11)); // NOI18N
        contrariedadLabel.setText("Contrariedad:");

        subcontrariedadLabel.setFont(new java.awt.Font("Tahoma", 1, 11)); // NOI18N
        subcontrariedadLabel.setText("Subcontrariedad:");

        subalternaLabel.setFont(new java.awt.Font("Tahoma", 1, 11)); // NOI18N
        subalternaLabel.setText("Subalternas:");

        def1Label.setText("Se oponen en cuanto la la verdad y falsedad.");

        def2Label.setText("No pueden ser verdaderas a la vez.");

        def3Label.setText("No pueden ser falsas a la vez.");

        def4Label.setText("Si la universal es verdadera, la particular lo sera tambien. Si la particular es falsa, la universal lo sera tambien.");

        javax.swing.GroupLayout bottomPanelLayout = new javax.swing.GroupLayout(bottomPanel);
        bottomPanel.setLayout(bottomPanelLayout);
        bottomPanelLayout.setHorizontalGroup(
                bottomPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(bottomPanelLayout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(bottomPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                .addGroup(bottomPanelLayout.createSequentialGroup()
                                        .addComponent(contradiccionLabel)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(def1Label))
                                .addGroup(bottomPanelLayout.createSequentialGroup()
                                        .addComponent(contrariedadLabel)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(def2Label))
                                .addGroup(bottomPanelLayout.createSequentialGroup()
                                        .addComponent(subcontrariedadLabel)
                                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                        .addComponent(def3Label))
                                .addGroup(bottomPanelLayout.createSequentialGroup()
                                .addComponent(subalternaLabel)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addComponent(def4Label)))
                        .addContainerGap(62, Short.MAX_VALUE))
        );
        bottomPanelLayout.setVerticalGroup(
                bottomPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(bottomPanelLayout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(bottomPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                .addComponent(contradiccionLabel)
                                .addComponent(def1Label))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(bottomPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                .addComponent(contrariedadLabel)
                                .addComponent(def2Label))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(bottomPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                .addComponent(subcontrariedadLabel)
                                .addComponent(def3Label))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(bottomPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                .addComponent(subalternaLabel)
                                .addComponent(def4Label))
                        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        mainPanel.setBorder(javax.swing.BorderFactory.createTitledBorder(new javax.swing.border.LineBorder(new java.awt.Color(204, 204, 204), 1, true), "Cuadro de la oposicion"));

        cuadroPanel.setBackground(new java.awt.Color(255, 255, 255));
        cuadroPanel.setBorder(javax.swing.BorderFactory.createBevelBorder(javax.swing.border.BevelBorder.LOWERED));

        cuadroLabel.setIcon(Utiles.createImageIcon("/gui/images/oposicion/Reset.png")); // NOI18N//todo

        referenciaPanel.setBackground(new java.awt.Color(255, 255, 255));
        referenciaPanel.setBorder(javax.swing.BorderFactory.createTitledBorder(new javax.swing.border.LineBorder(new java.awt.Color(204, 204, 204), 1, true), "Referencias"));

        vLabel.setFont(new java.awt.Font("Tahoma", 1, 48)); // NOI18N
        vLabel.setIcon(Utiles.createImageIcon("/gui/images/oposicion/buttongreen.png")); // NOI18N
        vLabel.setText("V");

        fLabel.setFont(new java.awt.Font("Tahoma", 1, 48)); // NOI18N
        fLabel.setIcon(Utiles.createImageIcon("/gui/images/oposicion/buttonred.png")); // NOI18N
        fLabel.setText("F");

        v_fLabel.setFont(new java.awt.Font("Tahoma", 1, 48)); // NOI18N
        v_fLabel.setIcon(Utiles.createImageIcon("/gui/images/oposicion/buttonyellow.png")); // NOI18N
        v_fLabel.setText("V/F");

        javax.swing.GroupLayout referenciaPanelLayout = new javax.swing.GroupLayout(referenciaPanel);
        referenciaPanel.setLayout(referenciaPanelLayout);
        referenciaPanelLayout.setHorizontalGroup(
                referenciaPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, referenciaPanelLayout.createSequentialGroup()
                        .addContainerGap(33, Short.MAX_VALUE)
                        .addGroup(referenciaPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                .addComponent(vLabel)
                                .addComponent(fLabel)
                                .addComponent(v_fLabel))
                        .addContainerGap())
        );
        referenciaPanelLayout.setVerticalGroup(
                referenciaPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(referenciaPanelLayout.createSequentialGroup()
                        .addComponent(vLabel)
                        .addGap(28, 28, 28)
                        .addComponent(fLabel)
                        .addGap(27, 27, 27)
                        .addComponent(v_fLabel)
                        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
        );

        resetButton.setText("Reset");
        resetButton.addActionListener(new ActionListener() {
            public void actionPerformed(ActionEvent e) {
                reset();
            }
        });

        aLabel.setFont(new java.awt.Font("Tahoma", 1, 18)); // NOI18N
        aLabel.setText("A");

        eLabel.setFont(new java.awt.Font("Tahoma", 1, 18)); // NOI18N
        eLabel.setText("E");

        iLabel.setFont(new java.awt.Font("Tahoma", 1, 18)); // NOI18N
        iLabel.setText("I");

        oLabel.setFont(new java.awt.Font("Tahoma", 1, 18)); // NOI18N
        oLabel.setText("O");

        aVerdaderaButton.setText("Verdadera");
        aVerdaderaButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                setAverdaderaOfalsa(true);
            }
        });

        aFalsaButton.setText("Falsa");
        aFalsaButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                setAfalsaOverdadera(true);
            }
        });

        eVerdaderaButton.setText("Verdadera");
        eVerdaderaButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                setEverdaderaIfalsa(true);
            }
        });

        eFalsaButton.setText("Falsa");
        eFalsaButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                setEfalsaIverdadera(true);
            }
        });

        iVerdaderaButton.setText("Verdadera");
        iVerdaderaButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                setEfalsaIverdadera(false);
            }
        });

        iFalsaButton.setText("Falsa");
        iFalsaButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                setEverdaderaIfalsa(false);
            }
        });

        oVerdaderaButton.setText("Verdadera");
        oVerdaderaButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                setAfalsaOverdadera(false);
            }
        });

        oFalsaButton.setText("Falsa");
        oFalsaButton.addActionListener(new java.awt.event.ActionListener() {
            public void actionPerformed(java.awt.event.ActionEvent evt) {
                setAverdaderaOfalsa(false);
            }
        });

        javax.swing.GroupLayout cuadroPanelLayout = new javax.swing.GroupLayout(cuadroPanel);
        cuadroPanel.setLayout(cuadroPanelLayout);
        cuadroPanelLayout.setHorizontalGroup(
                cuadroPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(cuadroPanelLayout.createSequentialGroup()
                                .addGap(26, 26, 26)
                                .addComponent(cuadroLabel)
                                .addGroup(cuadroPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                                .addGroup(cuadroPanelLayout.createSequentialGroup()
                                        .addGap(18, 18, 18)
                                        .addComponent(referenciaPanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                                        .addContainerGap())
                                .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, cuadroPanelLayout.createSequentialGroup()
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addComponent(resetButton)
                                .addGap(72, 72, 72))))
                        .addGroup(cuadroPanelLayout.createSequentialGroup()
                        .addGap(44, 44, 44)
                        .addGroup(cuadroPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(cuadroPanelLayout.createSequentialGroup()
                                .addGap(41, 41, 41)
                                .addComponent(aLabel)
                                .addGap(70, 70, 70)
                                .addComponent(eLabel)
                                .addGap(80, 80, 80)
                                .addComponent(iLabel)
                                .addGap(76, 76, 76)
                                .addComponent(oLabel))
                        .addGroup(cuadroPanelLayout.createSequentialGroup()
                        .addGroup(cuadroPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.TRAILING, false)
                                .addComponent(aFalsaButton, javax.swing.GroupLayout.Alignment.LEADING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addComponent(aVerdaderaButton, javax.swing.GroupLayout.Alignment.LEADING))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(cuadroPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                                .addComponent(eFalsaButton, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addComponent(eVerdaderaButton))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(cuadroPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                                .addComponent(iFalsaButton, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addComponent(iVerdaderaButton))
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addGroup(cuadroPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING, false)
                        .addComponent(oFalsaButton, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addComponent(oVerdaderaButton)))))
        );
        cuadroPanelLayout.setVerticalGroup(
                cuadroPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(cuadroPanelLayout.createSequentialGroup()
                                .addGap(23, 23, 23)
                                .addComponent(cuadroLabel)
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addGroup(cuadroPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(eLabel)
                                        .addComponent(aLabel)
                                        .addComponent(iLabel)
                                        .addComponent(oLabel))
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addGroup(cuadroPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(aVerdaderaButton)
                                        .addComponent(eVerdaderaButton)
                                        .addComponent(iVerdaderaButton)
                                        .addComponent(oVerdaderaButton))
                                .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                                .addGroup(cuadroPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.BASELINE)
                                        .addComponent(aFalsaButton)
                                        .addComponent(eFalsaButton)
                                        .addComponent(iFalsaButton)
                                        .addComponent(oFalsaButton))
                                .addContainerGap())
                        .addGroup(cuadroPanelLayout.createSequentialGroup()
                        .addGap(50, 50, 50)
                        .addComponent(referenciaPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.UNRELATED)
                        .addComponent(resetButton)
                        .addGap(265, 265, 265))
        );

        javax.swing.GroupLayout mainPanelLayout = new javax.swing.GroupLayout(mainPanel);
        mainPanel.setLayout(mainPanelLayout);
        mainPanelLayout.setHorizontalGroup(
                mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, mainPanelLayout.createSequentialGroup()
                        .addContainerGap(14, Short.MAX_VALUE)
                        .addComponent(cuadroPanel, javax.swing.GroupLayout.PREFERRED_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addContainerGap())
        );
        mainPanelLayout.setVerticalGroup(
                mainPanelLayout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(javax.swing.GroupLayout.Alignment.TRAILING, mainPanelLayout.createSequentialGroup()
                        .addContainerGap(javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addComponent(cuadroPanel, javax.swing.GroupLayout.PREFERRED_SIZE, 528, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addGap(28, 28, 28))
        );

        javax.swing.GroupLayout layout = new javax.swing.GroupLayout(this);
        this.setLayout(layout);
        layout.setHorizontalGroup(
                layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(layout.createSequentialGroup()
                        .addContainerGap()
                        .addGroup(layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                                .addComponent(mainPanel, javax.swing.GroupLayout.Alignment.TRAILING, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                                .addComponent(bottomPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE))
                        .addContainerGap())
        );
        layout.setVerticalGroup(
                layout.createParallelGroup(javax.swing.GroupLayout.Alignment.LEADING)
                        .addGroup(layout.createSequentialGroup()
                        .addComponent(mainPanel, javax.swing.GroupLayout.PREFERRED_SIZE, 567, javax.swing.GroupLayout.PREFERRED_SIZE)
                        .addPreferredGap(javax.swing.LayoutStyle.ComponentPlacement.RELATED)
                        .addComponent(bottomPanel, javax.swing.GroupLayout.DEFAULT_SIZE, javax.swing.GroupLayout.DEFAULT_SIZE, Short.MAX_VALUE)
                        .addContainerGap())
        );
    }

    private void reset() {
        aVerdaderaButton.setBackground(new Color(240, 240, 240));
        aFalsaButton.setBackground(new Color(240, 240, 240));
        eVerdaderaButton.setBackground(new Color(240, 240, 240));
        eFalsaButton.setBackground(new Color(240, 240, 240));
        iVerdaderaButton.setBackground(new Color(240, 240, 240));
        iFalsaButton.setBackground(new Color(240, 240, 240));
        oVerdaderaButton.setBackground(new Color(240, 240, 240));
        oFalsaButton.setBackground(new Color(240, 240, 240));
        cuadroLabel.setIcon(Utiles.createImageIcon("/gui/images/oposicion/Reset.png"));

    }

    private void setAfalsaOverdadera(boolean isA) {
        aVerdaderaButton.setBackground(new Color(240, 240, 240));
        if (isA) {
            aFalsaButton.setBackground(new Color(51, 255, 153));
        } else {
            aFalsaButton.setBackground(new Color(240, 240, 240));
        }
        eVerdaderaButton.setBackground(new Color(240, 240, 240));
        eFalsaButton.setBackground(new Color(240, 240, 240));
        iVerdaderaButton.setBackground(new Color(240, 240, 240));
        iFalsaButton.setBackground(new Color(240, 240, 240));
        if (!isA) {
            oVerdaderaButton.setBackground(new Color(51, 255, 153));
        } else {
            oVerdaderaButton.setBackground(new Color(240, 240, 240));
        }
        oFalsaButton.setBackground(new Color(240, 240, 240));
        cuadroLabel.setIcon(Utiles.createImageIcon("/gui/images/oposicion/Afalsa_Overdadera.png"));
    }

    private void setAverdaderaOfalsa(boolean isA) {
        if (isA) {
            aVerdaderaButton.setBackground(new Color(51, 255, 153));
        } else {
            aVerdaderaButton.setBackground(new Color(240, 240, 240));
        }
        aFalsaButton.setBackground(new Color(240, 240, 240));
        eVerdaderaButton.setBackground(new Color(240, 240, 240));
        eFalsaButton.setBackground(new Color(240, 240, 240));
        iVerdaderaButton.setBackground(new Color(240, 240, 240));
        iFalsaButton.setBackground(new Color(240, 240, 240));
        oVerdaderaButton.setBackground(new Color(240, 240, 240));
        if (!isA) {
            oFalsaButton.setBackground(new Color(51, 255, 153));
        } else {
            oFalsaButton.setBackground(new Color(240, 240, 240));
        }
        cuadroLabel.setIcon(Utiles.createImageIcon("/gui/images/oposicion/Averdadera_Ofalsa.png"));
    }

    private void setEverdaderaIfalsa(boolean isE) {
        if (isE) {
            eVerdaderaButton.setBackground(new Color(51, 255, 153));
        } else {
            eVerdaderaButton.setBackground(new Color(240, 240, 240));
        }
        aVerdaderaButton.setBackground(new Color(240, 240, 240));
        aFalsaButton.setBackground(new Color(240, 240, 240));
        eFalsaButton.setBackground(new Color(240, 240, 240));
        iVerdaderaButton.setBackground(new Color(240, 240, 240));
        oVerdaderaButton.setBackground(new Color(240, 240, 240));
        oFalsaButton.setBackground(new Color(240, 240, 240));
        if (!isE) {
            iFalsaButton.setBackground(new Color(51, 255, 153));
        } else {
            iFalsaButton.setBackground(new Color(240, 240, 240));
        }
        cuadroLabel.setIcon(Utiles.createImageIcon("/gui/images/oposicion/Everdadera_Ifalsa.png"));
    }

    private void setEfalsaIverdadera(boolean isE) {
        eVerdaderaButton.setBackground(new Color(240, 240, 240));
        if (isE) {
            eFalsaButton.setBackground(new Color(51, 255, 153));
        } else {
            eFalsaButton.setBackground(new Color(240, 240, 240));
        }
        aVerdaderaButton.setBackground(new Color(240, 240, 240));
        aFalsaButton.setBackground(new Color(240, 240, 240));
        oVerdaderaButton.setBackground(new Color(240, 240, 240));
        oFalsaButton.setBackground(new Color(240, 240, 240));
        if (!isE) {
            iVerdaderaButton.setBackground(new Color(51, 255, 153));
        } else {
            iVerdaderaButton.setBackground(new Color(240, 240, 240));
        }
        iFalsaButton.setBackground(new Color(240, 240, 240));
        cuadroLabel.setIcon(Utiles.createImageIcon("/gui/images/oposicion/EfalsaIverdadera.png"));
    }
}